home *** CD-ROM | disk | FTP | other *** search
/ C/C++ Users Group Library 1996 July / C-C++ Users Group Library July 1996.iso / vol_400 / 431_01 / packet.doc < prev    next >
Text File  |  1994-10-01  |  1KB  |  22 lines

  1. packet buffer and handshaking...
  2.  
  3. PACKET
  4.   BYTE  packetID[2] -- KY -- request from server
  5.                        LY -- reply from server
  6.                        RP -- resent last packet, either direction
  7.   WORD  length      -- number of bytes in this packet
  8.                        the entire packet (including header)
  9.   WORD  notlength   -- ~length (used to verify correctness)
  10.   DWORD crc32       -- 32 bit CRC, calculated over the entire packet,
  11.                        with this value set to 0 for the calculation
  12.   WORD  cmd         -- for the server, this is the result of the operation
  13.                        for the client, this is the code of the operation to
  14.                        be performed
  15.   BYTE  data[]      -- any additional data to be sent either direction
  16. -----------------------------------------------------------
  17. a basic assumtion in this is that only request can be processed in either
  18. direction at a time, but requests can go in either direction. if both
  19. directions are going simultaneously, a full packet must be transmitted
  20. in one direction first. 
  21.  
  22.